<?php

/*
 * 预报入库数据类
 */
class Application_Model_DbTable_ingstoreproduct extends Application_Model_DbTable_DomainObject{
    
        protected $_name = 'uuch_ingstore_product';	
        
	public function getMapper(){
		return array('id','ingstoreid','productid','productname','url','image','state');
	}

        /*
         * 
         */
        public function  getbyingstoreid($ingstoreid){
            $db = $this->getAdapter();
            $filter = $db->quoteInto('ingstoreid = ?', $ingstoreid);            
            $rows = $this->fetchAll($filter,'id');
            
            $result = array();
            foreach ($rows as $row){
                array_push($result,$this->convertRowToObject($row));                    
            }           
            return $result;
        }
}
?>
